/* 动态按钮按下效果 */
.glass-button, .control-btn, .tab-btn, .save-btn, .close-btn {
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    position: relative;
    overflow: hidden;
    /* 移除H5页面默认的蓝色高亮效果 */
    -webkit-tap-highlight-color: transparent;
}

/* 所有按钮通用的按下效果 */
.glass-button:active, 
.control-btn:active, 
.tab-btn:active, 
.save-btn:active,
.close-btn:active {
    transform: scale(0.95);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3), 
                inset 0 0 15px rgba(255, 255, 255, 0.1);
}

/* 玻璃按钮特定的按下效果 */
.glass-button:active {
    background: linear-gradient(135deg, 
                rgba(255, 255, 255, 0.25) 0%, 
                rgba(255, 255, 255, 0.1) 100%);
    border-color: rgba(255, 255, 255, 0.4);
}

/* 控制按钮特定的按下效果 */
.control-btn:active {
    background: linear-gradient(135deg, 
                rgba(100, 181, 246, 0.8) 0%, 
                rgba(66, 165, 245, 0.6) 100%);
    box-shadow: 0 5px 20px rgba(66, 165, 245, 0.4),
                inset 0 0 10px rgba(255, 255, 255, 0.2);
}

/* 标签按钮按下效果 */
.tab-btn:active {
    background: linear-gradient(135deg, 
                rgba(76, 175, 80, 0.8) 0%, 
                rgba(56, 142, 60, 0.6) 100%);
    color: white;
}

/* 保存按钮按下效果 */
.save-btn:active {
    background: linear-gradient(135deg, 
                rgba(255, 193, 7, 0.8) 0%, 
                rgba(255, 160, 0, 0.6) 100%);
    box-shadow: 0 5px 20px rgba(255, 193, 7, 0.4);
}

/* 关闭按钮按下效果 */
.close-btn:active {
    background: linear-gradient(135deg, 
                rgba(244, 67, 54, 0.8) 0%, 
                rgba(229, 57, 53, 0.6) 100%);
    color: white;
    box-shadow: 0 5px 20px rgba(244, 67, 54, 0.4);
}

/* 赞助按钮的特殊效果 - 改为透明 */
#sponsorBtn {
    background: linear-gradient(135deg, 
                rgba(255, 255, 255, 0.15) 0%, 
                rgba(255, 255, 255, 0.05) 100%);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.9);
}

#sponsorBtn:hover {
    background: linear-gradient(135deg, 
                rgba(255, 255, 255, 0.25) 0%, 
                rgba(255, 255, 255, 0.1) 100%);
    border-color: rgba(255, 255, 255, 0.3);
}

#sponsorBtn:active {
    background: linear-gradient(135deg, 
                rgba(255, 255, 255, 0.35) 0%, 
                rgba(255, 255, 255, 0.15) 100%);
    box-shadow: 0 5px 25px rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.4);
}

/* 按钮涟漪效果 */
.glass-button::after, 
.control-btn::after, 
.tab-btn::after,
.save-btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.glass-button:active::after, 
.control-btn:active::after, 
.tab-btn:active::after,
.save-btn:active::after {
    width: 150px;
    height: 150px;
    opacity: 0;
}

/* 添加鼠标悬停效果增强交互感 */
.glass-button:hover, 
.control-btn:hover, 
.tab-btn:hover,
.save-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3),
                inset 0 0 20px rgba(255, 255, 255, 0.15);
}

.glass-button:hover {
    border-color: rgba(255, 255, 255, 0.5);
}

/* 添加图标动画 */
.glass-button i, .control-btn i, .save-btn i {
    transition: transform 0.3s ease;
}

.glass-button:active i, 
.control-btn:active i, 
.save-btn:active i {
    transform: scale(1.2);
}

/* 音乐控制按钮的特定效果 */
.music-controls .control-btn {
    transition: all 0.2s ease;
}

.music-controls .control-btn#playBtn:active {
    background: linear-gradient(135deg, 
                rgba(76, 175, 80, 0.9) 0%, 
                rgba(56, 142, 60, 0.7) 100%);
}

.music-controls .control-btn#stopBtn:active {
    background: linear-gradient(135deg, 
                rgba(244, 67, 54, 0.9) 0%, 
                rgba(229, 57, 53, 0.7) 100%);
}

/* 标签按钮激活状态 */
.tab-btn.active:active {
    background: linear-gradient(135deg, 
                rgba(33, 150, 243, 0.9) 0%, 
                rgba(30, 136, 229, 0.7) 100%);
    box-shadow: 0 5px 20px rgba(33, 150, 243, 0.4);
}

/* 音量滑块按下效果 */
.volume-slider::-webkit-slider-thumb {
    transition: all 0.2s ease;
}

.volume-slider::-webkit-slider-thumb:active {
    transform: scale(1.3);
    box-shadow: 0 0 10px rgba(33, 150, 243, 0.8);
}

/* 添加键盘焦点状态，支持键盘导航 */
.glass-button:focus-visible, 
.control-btn:focus-visible, 
.tab-btn:focus-visible,
.save-btn:focus-visible,
.close-btn:focus-visible {
    outline: 2px solid rgba(33, 150, 243, 0.8);
    outline-offset: 2px;
    box-shadow: 0 0 15px rgba(33, 150, 243, 0.5);
}

/* 禁用状态按钮 */
.glass-button:disabled, 
.control-btn:disabled, 
.tab-btn:disabled,
.save-btn:disabled {
    opacity: 0.5;
    transform: none !important;
    cursor: not-allowed;
}

.glass-button:disabled:active, 
.control-btn:disabled:active, 
.tab-btn:disabled:active,
.save-btn:disabled:active {
    transform: none !important;
    box-shadow: inherit !important;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .glass-button:active, 
    .control-btn:active, 
    .tab-btn:active, 
 .save-btn:active,
    .close-btn:active {
        transform: scale(0.97);
    }
}